<!DOCTYPE html>
<html lang="zh_CN" xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.ultraq.net.nz/web/thymeleaf/layout">

<head>
    <title th:text="${pageTitle}"></title>
    <div data-th-replace="layout/head-top"></div>
</head>
<body class="gray-bg">
    <div class="wrapper wrapper-content animated fadeInLeft">
        <div data-th-replace="common/functionDepict"></div>
        <div>
            <div class="row">
                <div class="pt10">
                    <div class="col-sm-12">
                        <div class="ibox">
                            <div th:attr="id='accountItem_'+${account['id']}"  class="ibox-content " th:class="${account['accountStatus']}=='FROZEN' ? 'stu-s-accountItem'">
                                <div th:if="${account['accountStatus']}=='FROZEN'"  class="stu-s-accountBg"><i class="fa fa-unlock-alt" title="账户冻结"></i></div>
                                <div class="team-members clearfix">
                                    <span class="pull-left m-r">
                                         <img th:if="${account['user']['avatar']}==null or ${account['user']['avatar']}==''" alt="member" class="img-circle" th:src="@{{path}/admin/v3/img/default/admin_userpace.jpg?v={v}(path=${staticPath},v=${v})}">
                                         <img alt="member" th:if="${account['user']['avatar']}!=null and ${account['user']['avatar']}!=''" class="img-circle" th:src="${account['user']['avatar']}">
                                    </span>
                                    <div><span class="c-999 fs14">账号：</span><span class="c-222 fs14">
                                         <span th:if="${account['user']['mobile']}==null or ${account['user']['mobile']}==''" class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="手机">—</span>
                                <span th:if="${account['user']['mobile']}!=null and ${account['user']['mobile']}!=''" class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="手机" th:text="${account['user']['mobile']}"></span>
                                <span th:if="${account['user']['email']}==null or ${account['user']['email']}==''" class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="邮箱">—</span>
                                <span th:if="${account['user']['email']}!=null and ${account['user']['email']}!=''" class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="邮箱" th:text="${account['user']['email']}"> </span>
                                <span th:if="${account['user']['mobile']}==null or ${account['user']['mobile']}==''"  class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="账号">—</span>
                                <span th:if="${account['user']['email']}!=null and ${account['user']['email']}!=''" class="c-master fs14 c-222" data-toggle="tooltip" data-placement="bottom" data-original-title="账号" th:text="${account['user']['loginAccount']}"> </span>
                                    </span></div>

                                </div>
                                <div class="row">
                                    <div class="col-sm-6">
                                        <span> 账户状态 </span>
                                        <div th:if="${account['user']['isavalible']}==1"><span class="badge badge-info">正常</span></div>
                                        <div th:if="${account['user']['isavalible']}==2"><span class="badge badge-danger">冻结</span></div>
                                    </div>
                                    <div class="col-sm-6 text-right">
                                        <span> 余额 </span>
                                        <h2 class="font-bold" >¥  <span th:attr="id='balance_'+${account.id}" th:text="${account['balance']}"> </span></h2>
                                    </div>
                                </div>
                                <div class="hr-line-dashed"></div>
                                <div class="row">
                                    <div class="col-sm-3">
                                        <div class="font-bold">银行转账</div>
                                        ¥<span th:attr="id='cashAmount_'+${account.id}" th:text="${account['cashAmount']}"></span> <i class="fa fa-level-up text-navy"></i>
                                            <!--<button  type="button" th:attr="data-id=${account['id']}" data-status="1" class="btn btn-xs btn-outline btn-primary ml10  userAccount">充值</button>-->
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="7" class="btn btn-xs btn-outline btn-primary ml10 userAccount">扣款</button>
                                    </div>
                                    <div class="col-sm-3">
                                        <div class="font-bold">冻结金额</div>
                                        <span class="todo-completed">¥<span th:attr="id='cashForzenAmount_'+${account['id']}"  th:text="${account['cashForzenAmount']}" ></span> <i class="fa fa-level-down text-navy"></i></span>
                                            <button   type="button" th:attr="data-id=${account['id']}" data-status="2" class="btn btn-xs btn-outline btn-primary ml10 userAccount">冻结</button>
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="3" class="btn btn-xs btn-outline btn-primary ml10 userAccount">解冻</button>

                                    </div>
                                    <div class="col-sm-3">
                                        <div class="font-bold">充值卡入账</div>
                                        ¥<span th:attr="id='vmAmount_'+${account['id']}"  th:text="${account['vmAmount']}" ></span><i class="fa fa-level-up text-navy"></i>
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="4" class="btn btn-xs btn-outline btn-primary ml10 userAccount">充值</button>
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="8" class="btn btn-xs btn-outline btn-primary ml10 userAccount">扣款</button>

                                    </div>
                                    <div class="col-sm-3">
                                        <div class="font-bold">冻结金额</div>
                                        <span class="todo-completed">¥<span th:attr="id='vmForzenAmount_'+${account['id']}"  th:text="${account['vmForzenAmount']}"></span> <i class="fa fa-level-down text-navy"></i></span>
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="5" class="btn btn-xs btn-outline btn-primary ml10 userAccount" >冻结</button>
                                            <button  type="button" th:attr="data-id=${account['id']}" data-status="6" class="btn btn-xs btn-outline btn-primary ml10 userAccount" >解冻</button>
                                    </div>
                                </div>
                                <div th:if="${account['accountStatus']}=='FROZEN'" class="hr-line-dashed"></div>
                                <div th:if="${account['accountStatus']}=='FROZEN'" class="text-center">
                                    <button  type="button" th:attr="data-id=${account['id']}" data-status="ACTIVE" class="btn btn-outline btn-white updateInfoStatus">解冻账户</button>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="pt10">
                    <div class="col-sm-12">
                        <div>
                            <div class="ibox-title">
                                <div class="row">
                                    <div class="col-sm-7">
                                        <a th:href="@{/admin/user/cus/userAccountInfo?userId={userId}(userId=${account['userId']})}"><span><button class="btn btn-white" data-toggle="tooltip" data-placement="top" title="刷新账户消费列表"><i class="fa fa-refresh"></i> 刷新账户消费列表</button></span></a>
                                    </div>
                                    <div class="col-sm-3">
                                        <form  role="form" class="form-inline search-form"   id="search-form">
                                            <input type="hidden" name="userId" th:value="${account['userId']}" />
                                            <div class="input-group opSearchBox">
                                                <input placeholder="输入账户历史内容描述" name="description" value="" class="input-sm form-control vam" type="text">
                                                <span class="input-group-btn"><button id="btn1" type="button" class="btn btn-sm btn-primary vam">搜索</button> </span>
                                            </div>
                                        </form>
                                    </div>
                                    <div class="col-sm-2 text-center">
                                        <a href="javascript: void(0);" id="advSearchshowBtn" class="vam">高级搜索操作 <i class="fa fa-angle-double-down"></i></a>
                                    </div>
                                </div>
                            </div>
                            <div class="oc-advSearch-box">
                                <div class="row">
                                    <div class="col-sm-4">
                                        <div class="pt10">
                                            <div class="checkbox">

                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-sm-8">
                                        <div class="pt10">
                                            <form  role="form" class="form-inline search-form">
                                                <select class="form-control mb10" name="actHistoryType" id="actHistoryType">
                                                    <option value="">请选择</option>
                                                    <th:block th:each="accountHistoryType : ${accountHistoryTypeList}">
                                                        <option  th:value="${accountHistoryType['value']}" th:text="${accountHistoryType['name']}"></option>
                                                    </th:block>
                                                </select>
                                                <select class="form-control mb10"  name="bizType" id="bizType">
                                                    <option value="">请选择</option>
                                                    <th:block th:each="accountBizType : ${accountBizTypeList}">
                                                        <option th:value="${accountBizType['value']}" th:text="${accountBizType['name']}"></option>
                                                    </th:block>
                                                </select>
                                                <div class="form-group" style="margin-bottom: 10px">
                                                    <input placeholder="请输入操作开始时间" id="startDate" name="startTime" value="" class="laydate-icon form-control layer-date" type="text">
                                                </div>
                                                <div class="form-group" style="margin-bottom: 10px">
                                                    <input placeholder="请输入操作结束时间" name="endTime" value="" id="endDate" class="laydate-icon form-control layer-date" type="text">
                                                    <input type="hidden" name="userId" th:value="${account['userId']}" />
                                                </div>
                                                <button class="btn btn-w-m btn-primary" id="btn2" type="button" style="margin-bottom: 10px">搜索</button>
                                            </form>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="oc-ibox-content" id="role-list-context">

                             </div>
                        </div>
                    </div>
                </div>
        </div>
    </div>
    </div>
    <div data-th-replace="layout/head-footer"></div>
    <script type="text/javascript" th:src="@{{path}/admin/business/user/account/account.js?v={v}(path=${staticPath},v=${v})}"> </script>
    <script type="text/javascript" th:src="@{{path}/admin/business/user/account/account_info.js?v={v}(path=${staticPath},v=${v})}"> </script>
    <script type="text/javascript" th:src="@{{path}/admin/libs/plugins/layer/laydate/laydate.js?v={v}(path=${staticPath},v=${v})}"></script>
</body>
</html>
